package com.imm.net.http.weather

import com.alibaba.fastjson2.JSONObject
import retrofit2.Call
import retrofit2.http.GET
import retrofit2.http.Headers
import retrofit2.http.Query
import retrofit2.http.QueryMap

/**
 * <p>------------------------------------------------------
 * <p>Copyright (C) 2020 wasu company, All rights reserved.
 * <p>------------------------------------------------------
 * <p>
 * <p>
 *
 * @author Created by zhangmz
 * @date on 2024/3/22
 */
interface WeatherDao {

    /**
     * 查询选择城市的背景
     * http://image.so.com/j?q=杭州&sn=1&pn=1&width=1080&height=1920
     */
    @Headers("Content-Type:application/json", "charset:utf-8")
    @GET("/j")
    fun queryImg(@Query("q") keyword: String): Call<JSONObject>

    /**
     * 查询选择城市的背景
     * http://image.so.com/j?q=杭州&sn=1&pn=1&width=1080&height=1920
     */
    @Headers("Content-Type:application/json", "charset:utf-8")
    @GET("/j")
    fun queryImg(@QueryMap map: Map<String, String>) : Call<JSONObject>

    @GET("/j")
    fun queryCityList(): Call<JSONObject>

}